The electronic devices currently available in the market, such as mobile phones, tablet PCs, automotive electronic products, are equipped with non-volatile storage devices. Flash memory is an electronic non-volatile computer storage medium that retains content without consuming power. Correctness of data stored in flash memory is important. Accordingly, it is desirable to avoid potential data loss in flash memory.